package com.zhijian.warehouse.manage.dao;

import com.zhijian.warehouse.manage.entity.po.StoreRecordProduct;
import com.zhijian.warehouse.manage.entity.vo.request.StoreRecordProductSearchVo;
import com.zhijian.warehouse.manage.entity.vo.response.StoreRecordProductVo;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface StoreRecordProductMapper {
    int deleteByPrimaryKey(Long id);

    int insert(StoreRecordProduct record);

    int insertSelective(StoreRecordProduct record);

    StoreRecordProduct selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(StoreRecordProduct record);

    int updateByPrimaryKey(StoreRecordProduct record);

    /**
     * 查询总数
     *
     * @param storeRecordProductSearchVo
     * @return
     */
    int count(StoreRecordProductSearchVo storeRecordProductSearchVo);

    /**
     * 查询列表
     *
     * @param storeRecordProductSearchVo
     * @return
     */
    List<StoreRecordProductVo> selectList(StoreRecordProductSearchVo storeRecordProductSearchVo);

    /**
     * 查询单个
     *
     * @param storeRecordProductSearchVo
     * @return
     */
    StoreRecordProductVo selectOne(StoreRecordProductSearchVo storeRecordProductSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    StoreRecordProductVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param storeRecordProductSearchVo
     * @return
     */
    void deleteByCondition(StoreRecordProductSearchVo storeRecordProductSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<StoreRecordProduct> entities);

    /**
     * 根据StoreRecordId查询列表
     *
     * @param storeRecordId
     * @return
     */
    List<StoreRecordProductVo> selectListByStoreRecordId(Long storeRecordId);

    /**
     * 根据ProductId查询列表
     *
     * @param productId
     * @return
     */
    List<StoreRecordProductVo> selectListByProductId(Long productId);

    /**
     * 根据WarehouseId查询列表
     *
     * @param warehouseId
     * @return
     */
    List<StoreRecordProductVo> selectListByWarehouseId(Long warehouseId);

    /**
     * 根据WarehouseLocationId查询列表
     *
     * @param warehouseLocationId
     * @return
     */
    List<StoreRecordProductVo> selectListByWarehouseLocationId(Long warehouseLocationId);
}